<?php
/**
 * 类名称
 * User: 13651
 * Time: 2025/10/22 11:20
 */

namespace App\Api\Controllers\Basequery;

use App\Api\Controllers\HuiPay\HuifuBaseController;
use App\Jobs\HuifuDataInfoJob;
use App\Models\HuifuConfigs;
use App\Models\HuifuMccCode;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\DB;

class HuifuTestController
{

    public function testImg(Request $request)
    {
        HuifuDataInfoJob::dispatch();
//        $info = HuifuConfigs::query()->where('config_id',1234)->first()->toArray();
//        $data = [
//            'req_seq_id'=>date('YmdHis'),
//            'req_date'=>date('Ymd'),
//            'file_type'=>'F07',
//        ];
//        $file = 'http://wanfutong.oss-cn-hangzhou.aliyuncs.com/165740_113.jpg';
//        $a = HuifuBaseController::getInstance()->picture($info,$file,$data);
//        var_dump($a);
//        $json = file_get_contents("https://cloudpnrcdn.oss-cn-shanghai.aliyuncs.com/opps/api/prod/download_file/MCC%E7%A0%81/%E6%B1%87%E4%BB%98mcc.json");
//        $code = json_decode($json,true);
//        foreach ($code as $k=>&$v){
//            $data = [
//                'mcc_name'=>$v['HFMCC名称'],
//                'mcc_code'=>$v['HFMCC code'],
//                'created_at'=>date('Y-m-d H:i:s'),
//                'updated_at'=>date('Y-m-d H:i:s'),
//            ];
//            HuifuMccCode::query()->insert($data);
//        }
    }
}